#ifndef VOLUMETOOL_H
#define VOLUMETOOL_H

#include <QWidget>
#include<QPaintEvent>
#include<QPainter>
#include<QGraphicsDropShadowEffect>

namespace Ui {
class VolumeTool;
}

class VolumeTool : public QWidget
{
    Q_OBJECT

public:
    explicit VolumeTool(QWidget *parent = nullptr);
    ~VolumeTool();

protected:
    //virtual void paintEvent(QPaintEvent* event)override;
    virtual bool eventFilter(QObject* object, QEvent* event)override;

public:
    void setVolume();
private slots:
    void onSilenceBtnClicked();

signals:
    void setSilence(bool isMuted);
    void setMusicVolume(int volumeRatio);

private:
    Ui::VolumeTool *ui;

    QGraphicsDropShadowEffect* shadowEffect;

    bool _isMuted;
    int _volumeRatio;
};

#endif // VOLUMETOOL_H
